Skip to content

fix: do not include n/a clinvar ids in mappings#206

Open
korikuzma wants to merge 2 commits intomasterfrom
issue-205
Open

fix: do not include n/a clinvar ids in mappings#206
korikuzma wants to merge 2 commits intomasterfrom
issue-205

Conversation

@korikuzma
Copy link
Collaborator

close #205

@korikuzma korikuzma self-assigned this Feb 12, 2026
@korikuzma korikuzma added the bug Something isn't working label Feb 12, 2026
@korikuzma
Copy link
Collaborator Author

@susannasiebert and @acoffman

I tried updating the test cache by using the staging API URL, but getting:

╰─$ civicpy update --hard    
WARNING:root:Getting all molecular_profiles. This may take a couple of minutes...
WARNING:root:Getting all genes. This may take a couple of minutes...
WARNING:root:Getting all factors. This may take a couple of minutes...
WARNING:root:Getting all fusions. This may take a couple of minutes...
WARNING:root:Getting all variants. This may take a couple of minutes...
Traceback (most recent call last):
  File "civicpy/.venv/bin/civicpy", line 10, in <module>
    sys.exit(cli())
             ^^^^^
  File "civicpy/.venv/lib/python3.12/site-packages/click/core.py", line 1485, in __call__
    return self.main(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "civicpy/.venv/lib/python3.12/site-packages/click/core.py", line 1406, in main
    rv = self.invoke(ctx)
         ^^^^^^^^^^^^^^^^
  File "civicpy/.venv/lib/python3.12/site-packages/click/core.py", line 1873, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "civicpy/.venv/lib/python3.12/site-packages/click/core.py", line 1269, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "civicpy/.venv/lib/python3.12/site-packages/click/core.py", line 824, in invoke
    return callback(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "civicpy/civicpy/cli.py", line 44, in update
    civic.update_cache(from_remote_cache=soft, local_cache_path=cache_save_path)
  File "civicpy/civicpy/civic.py", line 264, in update_cache
    variants = _get_elements_by_ids("variant", allow_cached=False, get_all=True)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "civicpy/civicpy/civic.py", line 1986, in _get_elements_by_ids
    e = _postprocess_response_element(e, element)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "civicpy/civicpy/civic.py", line 2088, in _postprocess_response_element
    raise Exception("Variant type {} not supported yet".format(e["__typename"]))
Exception: Variant type RegionVariant not supported yet

I tried doing a small workaround in 008ce6b to try to ignore region variants.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CivicGksMolecularProfile should ignore ClinVar IDs that are N/A

1 participant